<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="utf-8"/>
	<title></title>
	<script src="vue.js" type="text/javascript"></script>
</head>
<body>
	<div id="app">
		<input type="button" name="" id="" value="点我" @click="saySomething('老铁',666)" />
		<input type="text" value="" @keyup.enter="sayHi">
	</div>
<script>
	var app=new Vue({
		el:"#app",
		methods: {
			saySomething:function(p1,p2) {
				//console.log("打招呼");
				console.log(p1);
				console.log(p2);
			},
			sayHi:function(){
				alert("吃了吗？");
			}
		},
	})
</script>

</body>
</html>
